package com.leilei.serviceProject.domain.strategy.service.armory;

import com.leilei.serviceProject.domain.strategy.model.valobj.StrategyAwardCountSurplusVo;

/**
 * @author yanglei
 * @description 策略抽奖调度
 * @create 2024/10/21 14:46
 */
public interface IStrategyDispatch {
    /**
     * 获取抽奖策略装备的随机结果
     *
     * @param strategyId 策略ID
     * @Return 奖品id
     */
    Integer getRandomAwardId(Long strategyId);

    /**
     * 获取抽奖策略装备的权重随机结果
     *
     * @param strategyId      策略ID
     * @param ruleWeightValue 权重值
     * @Return 奖品id
     */
    Integer getRandomAwardId(Long strategyId, String ruleWeightValue);

    /**
     * 奖品库存扣减 使用decr方式扣减
     *
     * @param strategyId 策略ID
     * @param awardId    奖品ID
     * @Return 扣减结果
     */
    boolean awardStockDeduction(Long strategyId, Integer awardId);
}
